// 平台管理
import { DEFAULT_LAYOUT } from '../base';
import { AppRouteRecordRaw } from '../types';

const PLATFORM_MANAGEMENT: AppRouteRecordRaw = {
  path: '/platform-management',
  name: '平台管理',
  component: DEFAULT_LAYOUT,
  meta: {
    locale: 'menu.platform-management',
    requiresAuth: true,
    ignoreCache: true,
    icon: 'icon-settings',
    order: 10,
  },
  children: [
    {
      path: '/userManage',
      name: '用户管理',
      component: () =>
        import('@/views/platform-management/list/user-manage/index.vue'),
      meta: {
        locale: 'menu.userManage',
        requiresAuth: true,
        ignoreCache: true,
        roles: ['*'],
      },
    },
    {
      path: '/roleManage',
      name: '角色管理',
      component: () =>
        import('@/views/platform-management/list/role-manage/index.vue'),
      meta: {
        locale: 'menu.roleManage',
        requiresAuth: true,
        ignoreCache: true,
        roles: ['*'],
      },
    },
    {
      path: '/teamManage',
      name: '班组管理',
      component: () =>
        import('@/views/platform-management/list/team-manage/index.vue'),
      meta: {
        locale: 'menu.teamManage',
        requiresAuth: true,
        ignoreCache: true,
        roles: ['*'],
      },
    },
  ],
};

export default PLATFORM_MANAGEMENT;
